class Commitment < Event
  belongs_to :user
  
  def Commitment.update(myId, myName, myStart, myEnd, isMo, isTu, isWe, isTh, isFr, isSa, isSu)
    theCommit = Commitment.find(:first, :conditions => {:id => myId})
    theCommit.event_name = myName
    theCommit.start_time = myStart
    theCommit.stop_time = myEnd
    theCommit.monday = isMo
    theCommit.tuesday = isTu
    theCommit.wednesday = isWe
    theCommit.thursday = isTh
    theCommit.friday = isFr
    theCommit.saturday = isSa
    theCommit.sunday = isSu
    theCommit.save
  end
  
end
